package com.ms.education.easypoi.entity;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

/**
 * <p>
 * 该表为普通用户，可以访问前台界面
 * </p>
 *
 * @author ms
 * @since 2023-01-12
 */
@ToString
@Getter
@Setter
@TableName("edu_user")
@ApiModel(value = "User对象", description = "该表为普通用户，可以访问前台界面")
public class User implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty("微信openID")
    @TableField("open_id")
    private String openId;

    @ApiModelProperty("手机号")
    @TableField("mobile")
    @Excel(name = "mobile")
    private String mobile;

    @ApiModelProperty("密码")
    @TableField("password")
    @Excel(name = "password")
    private String password;

    @ApiModelProperty("昵称")
    @TableField("nickname")
    @Excel(name = "nickname")
    private String nickname;

    @ApiModelProperty("性别 1 女 2 男")
    @TableField("sex")
    @Excel(name = "sex")
    private Integer sex;

    @ApiModelProperty("年龄")
    @TableField("age")
    @Excel(name = "age")
    private Integer age;

    @ApiModelProperty("头像")
    @TableField("avatar")
    private String avatar;

    @ApiModelProperty("签名")
    @TableField("sign")
    private String sign;

    @ApiModelProperty("是否禁用 1（true）已禁用，  0（false）未禁用")
    @TableField("is_disabled")
    private Boolean isDisabled;

    @ApiModelProperty("逻辑删除 1（true）已删除， 0（false）未删除")
    @TableField("is_deleted")
    @TableLogic
    private Boolean isDeleted;

    @ApiModelProperty("创建时间")
    @TableField(value = "gmt_create", fill = FieldFill.INSERT)
    private Date gmtCreate;

    @ApiModelProperty("修改时间")
    @TableField(value = "gmt_modified", fill = FieldFill.INSERT_UPDATE)
    private Date gmtModified;


}
